



function bindActionCreators(actionCreators,dispatch){
    const boundActionCreators = {}
    for (const key in actionCreators) {
        const actionCreator = actionCreators[key]
        boundActionCreators[key] = function(){
            dispatch(actionCreator())
        }
    }
    return boundActionCreators
}
export default bindActionCreators


/**
{
    add(){
        return {type:ADD}
    },
    minus(){
        return {type:MINUS}
    }

}
*/

/**
{
    add(){
        dispatch(add())
    },
    minus(){
        dispatch(minus())
    }
}
 */